﻿@model IEnumerable<GameSchoolWeb.Models.NewsItem>
@{
    ViewBag.Title = "GameSchool";
}
<div id="templatemo_content">
    @if (User.IsInRole("Umsjonarmadur"))
    {
        <div class="templatemo_box">
            <h2>
                <span></span>Tilkynningar</h2>
            <div class="body">
                <div class="news_box">
                    <h3>
                        <a href="#">Tilkynning 1</a></h3>
                    <p>
                        Praesent accumsan porta odio eget hendrerit. Lorem ipsum dolor sit amet, consectetur
                        adipiscing elit. Etiam ut nunc nisl, in pellentesque mi.</p>
                </div>
                <div class="news_box">
                    <h3>
                        <a href="#">Tilkynning 2</a></h3>
                    <p>
                        Nam non nisl massa, vitae dapibus nisl. Vivamus iaculis gravida odio sed tempor.
                        Fusce tempor faucibus est, ac feugiat metus accumsan sit amet.</p>
                </div>
                <div class="news_box">
                    <h3>
                        <a href="#">Tilkynning 3</a></h3>
                    <p>
                        Praesent rhoncus faucibus nibh, non molestie lectus sagittis sed. Praesent ac sem
                        lectus. Cras molestie elit sit amet velit tincidunt imperdiet. Mauris nulla purus.</p>
                    <div class="cleaner">
                    </div>
                </div>
                <div class="tilkynningar">
                    <a href="#">Sjá allt</a></div>
                <div class="cleaner">
                </div>
            </div>
            <div class="box_bottom">
                <span></span>
            </div>
        </div>
    }
</div>
<!-- end of templatemo_content -->
<div id="templatemo_content">
    @if (User.IsInRole("Nemandi") || User.IsInRole("Kennari"))
    {
        <div class="templatemo_box">
            <h2>
                <span></span>Næstu verkefni og próf</h2>
            <div class="body">
                <p>
                    Hér kemur listi yfir næstu verkefni og próf</p>
            </div>
            <div class="box_bottom">
                <span></span>
            </div>
        </div>
        <div class="templatemo_box">
            <h2>
                <span></span>Tilkynningar</h2>
            <div class="body">
                @foreach (var item in Model)
                {   
                    <div class="news_box">
                        <h3>
                            <a href="#">@item.strNewsTitle </a>
                        </h3>
                        <p>@item.strNewsContent</p>
                    </div>
                }
                <div class="tilkynningar">
                    <a href="#">Fara upp</a></div>
                <div class="cleaner">
                </div>
            </div>
            <div class="box_bottom">
                <span></span>
            </div>
        </div>
    }
</div>
<!-- end of templatemo_content -->
